package cool.tsy.emos.wx.exception;

import lombok.Data;

/**
 * @author: hongxuan.wang
 * @date: Created in 2021/9/24 1:06
 * @description: 业务异常类
 * @mail: 1443424326@qq.com
 */
@Data
public class EmosException extends RuntimeException {

    private static final long serialVersionUID = -5479147692500888512L;

    private String msg;
    private int code = 500;

    public EmosException(String msg) {
        super(msg);
        this.msg = msg;
    }

    public EmosException(String msg, Throwable e) {
        super(msg, e);
        this.msg = msg;
    }

    public EmosException(String msg, int code) {
        super(msg);
        this.msg = msg;
        this.code = code;
    }

    public EmosException(String msg, int code, Throwable e) {
        super(msg, e);
        this.msg = msg;
        this.code = code;
    }
}
